<template>
  <div>
    <el-table :data="tableData" stripe style="width: 99.9%" height="450">
      <!-- <el-table-column prop="ir_id" label="接种ID"> </el-table-column>
      <el-table-column prop="user_uid" label="用户ID"> </el-table-column>
      <el-table-column prop="user_account" label="用户账号"> </el-table-column>
      <el-table-column prop="user_username" label="用户名"> </el-table-column> -->
      <el-table-column prop="count" label="接种次数"> </el-table-column>
       <el-table-column prop="booking_time" label="预约时间" ></el-table-column>
      <el-table-column prop="inoculate_time" label="接种时间" sortable>
      </el-table-column>
    </el-table>
  </div>
</template>

<script>
import axios from "axios";
axios.defaults.baseURL = "http://localhost:8888";
export default {
  name: "OnlyInotable",
  data() {
    return {
      tableData: [
        {
          uid: 1,
          account: 111,
          username: "and",
          password: "123",
        },
      ],
      form: {},
      value: "",
      uid: window.sessionStorage.getItem("userId"),
    };
  },
  created() {
    this.load();
  },
  methods: {
    // 渲染所有的用户信息
    load() {
      axios
        .get(`/inoculation/selectInoculationByUserId/${this.uid}`)
        .then((respose) => {
          this.tableData = respose.data.data;
          console.log(this.tableData);
        });
    },
  },
};
</script>

<style scoped>
.search {
  padding: 10px;
  /* width: 230px; */
}
select {
  width: 150px;
  height: 40px;
  padding: 0 15px;
  border: 1px solid #dcdfe6;
  border-radius: 4px;
  color: #606266;
  line-height: 40px;
  font-size: 13px;
}
</style>